package service;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import entity.Choose;
import entity.Question;
import entity.Survey;
import mapper.QuestionMapper;

@Service
public class QuestionService {

	@Resource
	private QuestionMapper questionMapper;

	public QuestionMapper getQuestionMapper() {
		return questionMapper;
	}

	public void setQuestionMapper(QuestionMapper questionMapper) {
		this.questionMapper = questionMapper;
	}

	public boolean addQuestion(Question question){
		return questionMapper.addQuestion(question);
	}
	
	public boolean addSurvey(Survey survey){
		return questionMapper.addSurvey(survey);
	}
	
	public boolean addChoose(Choose choose){
		return questionMapper.addChoose(choose);
	}
	
	public Question queryQuestionId(Question question){
		return questionMapper.queryQuestionId(question);
	}

	
}
